<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
	<title>网上商城系统</title>
	<link href="css/index.css" rel="stylesheet" type="text/css" />
	<script type="text/javascript" src="js/jquery-1.6.1.min.js"></script>
</head>
  
<body>
	<%@include file="public/head.jsp" %>
	<div id="hr-body">
		<div class="hr-body-content">
			<table class="hr-body-layout" width="100%">
				<tbody>
					<tr>
						<%@include file="public/left.jsp" %>
						<td class="hr-bl-right" style="padding-left: 0pt;" valign="top">
							<table>
								<tbody>
									<tr>
										<td valign="top" width="434px">
											<div class="hr-index-flashad">
											<script type="text/javascript">
												var swf_width=430;/*修改flash宽，图片广告需要适应此宽度*/
												var swf_height=270;/*修改flash高，图片广告需要适应此高度*/
												var src="images/";
												var files=src+'new_1.jpg'+'|'+src+'new_2.jpg'+'|'+src+'new_3.jpg'+'|'+src+'new_4.jpg';/*替换banner.gif等更换显示图片*/
												var links='http://www.feeloc.cn|http://www.feeloc.cn/|http://www.feeloc.cn|http://www.feeloc.cn';/*修改按钮链接,注意链接中的&要用%26替换*/
												var texts='';/*广告标题部分*/
												document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="'+ swf_width +'" height="'+ swf_height +'">');
												document.write('<param name="movie" value="images/bcastr3.swf"><param name="quality" value="high">');
												document.write('<param name="menu" value="false"><param name=wmode value="transparent">');
												document.write('<param name="FlashVars" value="bcastr_file='+files+'&bcastr_link='+links+'&bcastr_title='+texts+'">');
												document.write('<images/bcastr3.swf" wmode="opaque" FlashVars="bcastr_file='+files+'&bcastr_link='+links+'&bcastr_title='+texts+'& menu="false" quality="high" width="'+ swf_width +'" height="'+ swf_height +'" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />'); 
												document.write('</object>'); 
											</script>
											<div id="ie-bug-fix">
											<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" height="270" width="430">
												<param name="movie" value="images/bcastr3.swf">
												<param name="quality" value="high">
												<param name="menu" value="false">
												<param name="wmode" value="transparent">
												<param name="FlashVars" value="images/new_1.jpg|images/new_2.jpg|images/new_3.jpg|images/new_4.jpg&amp;bcastr_link=http://www.feeloc.cn|http://www.feeloc.cn|http://www.feeloc.cn|http://www.feeloc.cn">
												<embed width="430" height="270" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" quality="high" false="" flashvars="bcastr_file=images/new_1.jpg|images/new_2.jpg|images/new_3.jpg|images/new_4.jpg&amp;bcastr_link=http://www.feeloc.cn|http://www.feeloc.cn|http://www.feeloc.cn|http://www.feeloc.cn&amp;bcastr_title=&amp; menu=" wmode="opaque" src="images/bcastr3.swf">
											</object>
											</div>
											<script type="text/javascript">
												$(function(){
													if($.browser.msie){
														$('#ie-bug-fix').hide();
													}
												});
											</script>
											</div>
										</td>
										<td id="hr-news" valign="top">
											<div class="hr-mod-panel">
												<div class="hr-panel-title">
													<div id="hr-news-handle">	
														<span class="cur" onmouseover="secNews(0,this)" id="first-news-handle">活动公告</span>
														<span onmouseover="secNews(1,this)">行业动态</span>
														<span onmouseover="secNews(2,this)">每日促销</span>
													</div>
												</div>
												<div id="hr-news-panel">
													<div style="">
														<table border="0" cellpadding="0" cellspacing="5" width="98%">
															<tbody>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="#">韩媛媛</a></td>
																</tr>
																<tr>
																	<td width="7%"></td>
																	<td align="right" width="93%"><a href="#?gOo=article_list.dwt&amp;acat=4">More...</a></td>
																</tr>
															</tbody>
														</table>
													</div>

													<div style="display: none;">
														<table border="0" cellpadding="0" cellspacing="5" width="98%">
															<tbody>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="http://www.feeloc.cn">韩媛媛的博客要焕发生机</a></td>
																</tr>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="http://www.feeloc.cn">韩媛媛的博客要焕发生机</a></td>
																</tr>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="http://www.feeloc.cn">韩媛媛的博客要焕发生机</a></td>
																</tr>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="http://www.feeloc.cn">韩媛媛的博客要焕发生机</a></td>
																</tr>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="http://www.feeloc.cn">韩媛媛的博客要焕发生机</a></td>
																</tr>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="http://www.feeloc.cn">韩媛媛的博客要焕发生机</a></td>
																</tr>
																<tr>
																	<td width="7%"><img src="images/sj.gif" alt="" height="8" width="4"></td>
																	<td align="left" width="93%"><a href="http://www.feeloc.cn">韩媛媛的博客要焕发生机</a></td>
																</tr>
															</tbody>
														</table>
													</div>
										
													<div style="display: none;">
														<table border="0" cellpadding="0" cellspacing="5" width="98%">
															<tbody>
																<tr>
																	<td>levis 1853</td>
																	<td align="left">200元/双</td>	
																</tr>
																<tr></tr>
																<tr>
																	<td>levis 1853</td>
																	<td align="left">200元/双</td>	
																</tr>
																<tr>
																</tr>
																<tr>
																	<td>levis 1853</td>
																	<td align="left">200元/双</td>	
																</tr>
																<tr>
																</tr>
																<tr>
																</tr>
																<tr>
																	<td colspan="2" align="right" width="7%"><font style="font-weight:700;">2012-4-28</font></td>
																</tr>
															</tbody>
														</table>
														<img src="images/mrjj.png" />
													</div>
												</div>
											</div>
										</td>
									</tr>
								</tbody>
							</table>
								
							<script>
								void function(){
									var bt=new Array(2);
									var board=document.getElementById('hr-news-panel');
									var divs=board.getElementsByTagName('div');
									secNews=function(index,handle){
										if(handle.className=='cur')
											return;
										divs[index].style.display='block';
										handle.className='cur';
										if(bt[0]){
											bt[0].className='';
											bt[1].style.display='none';
										}else{
											document.getElementById('first-news-handle').className='';
											divs[0].style.display='none';
										}
										bt=[handle,divs[index]];
									};
								}();
							</script>
				 
							<!--新品展示-->
							<div class="hr-mod2-panel">
								<div class="hr-panel2-title"><h3>新品展示</h3></div>
								<div class="hr-panel2-body" id="hr-newgoods-show">
									<table>
										<tbody>
											<tr>
											<s:iterator value="newproducts" id="product">
											<td class="hr-goods-show">
												<a href="showproduct?cid=${product.categoryId}" class="gpic"><img width="100px" height="100px" src="goods-images/${product.id}.jpg" alt="${product.name}" border="0"></a>
												<ul>
													<li class="gname"><a href="showproduct?cid=${product.categoryId}">${product.name}</a></li>
													<li class="hrpirce">￥${product.memberPrice}</li>
												</ul>									  
											</td>
											</s:iterator>
											<s:iterator value="newproducts" id="product">
											<td class="hr-goods-show">
												<a href="showproduct?cid=${product.categoryId}" class="gpic"><img width="100px" height="100px" src="goods-images/${product.id}.jpg" alt="${product.name}" border="0"></a>
												<ul>
													<li class="gname"><a href="showproduct?cid=${product.categoryId}">${product.name}</a></li>
													<li class="hrpirce">￥${product.memberPrice}</li>
												</ul>									  
											</td>
											</s:iterator>
											</tr>
										</tbody>
									</table>
								</div>
								<a class="hr-tag hr-new-tag" href="#">&nbsp;</a>
							</div>

							<script>
								/*新品长廊 js
									@anthor feeloc
								 */
								void function(){
									var duration=35;/*毫秒*/
									var _this=document.getElementById('hr-newgoods-show');
									var scrollHandleSize=_this.offsetWidth-(_this.scrollWidth-_this.offsetWidth);
									var mouseOver=false;
									var point=1;
									var gpics=_this.getElementsByTagName('img');
									for(var i=0;i<gpics.length;i++){
										gpics[i].onmouseover=function(){
											clearTimeout(effect);
											mouseOver=true;
										};
										gpics[i].onmouseout=function(){
											mouseOver=false;
											clearTimeout(effect);
											effect();
										};
									}
									var effect=function(){
										if(mouseOver)return;
										if(_this.scrollLeft<=0){
											/*point=true;*/
										}
										if((_this.scrollLeft+scrollHandleSize)>=_this.offsetWidth){
											/*point=false;*/
											_this.scrollLeft=0;
										}
										if(point){										    
											_this.scrollLeft+=1;
										}else{
											_this.scrollLeft-=1;
										}   
										return setTimeout(arguments.callee,duration);
									};
									effect();
								}();
							</script>
								 
							<!--热卖商品-->
							<div class="hr-mod2-panel" id="hr-hot-panel">
								<div class="hr-panel2-title">
									<h3>超值热卖</h3>
									<ul class="hr-float-list" id="hr-hot-handle">
										<li class="current" id="first-hot-handle" onmouseover="secHotBody(0,this)">
											<a href="#" handle="c6">热门手机</a>
										</li>
										<li onmouseover="secHotBody(1,this)">
											<a href="#" handle="c5">个人电脑</a>
										</li>
										<li  onmouseover="secHotBody(2,this)">
											<a href="#" handle="c10">热卖潮鞋</a>
										</li>
										<li onmouseover="secHotBody(3,this)">
											<a href="#"handle="c11">热门相机</a>
										</li>
									</ul>
								</div>
									
								<div id="hr-hot-body">
									<div class="hr-panel2-body" forcat="c6" style="display: block;">
										<table width="100%">
											<tbody>
												<tr>
												<s:iterator value="phones" id="product">
												<td valign="top" width="25%">
													<div class="hr-goods-show">
														<a href="#" class="gpic">
															<img width="120px" height="120px" src="goods-images/${product.id}.jpg" alt="${product.name}" border="0">
														</a>
														<ul>
															<li class="gname"><a href="#">${product.name}</a></li>
															<li class="gmpirce"><b>市场均价:</b>￥${product.memberPrice}</li>
															<li class="hrpirce"><b>会员实价:</b>￥${product.normalPrice}</li>			
														</ul>									  
													</div>
												</td>
												</s:iterator>
												</tr>
											</tbody>
										</table>
									</div>
									
									<div class="hr-panel2-body" forcat="c5" style="display: block;">
										<table width="100%">
											<tbody>
												<tr>
												<s:iterator value="computers" id="product">
												<td valign="top" width="25%">
													<div class="hr-goods-show">
														<a href="#" class="gpic">
															<img width="120px" height="120px" src="goods-images/${product.id}.jpg" alt="${product.name}" border="0">
														</a>
														<ul>
															<li class="gname"><a href="#">${product.name}</a></li>
															<li class="gmpirce"><b>市场均价:</b>￥${product.memberPrice}</li>
															<li class="hrpirce"><b>会员实价:</b>￥${product.normalPrice}</li>			
														</ul>									  
													</div>
												</td>
												</s:iterator>
												</tr>
											</tbody>
										</table>
									</div>
									
									<div class="hr-panel2-body" forcat="c10" style="display: none;">
										<table width="100%">
											<tbody>
												<tr>
												<s:iterator value="shoes" id="product">
												<td valign="top" width="25%">
													<div class="hr-goods-show">
														<a href="#" class="gpic">
															<img width="120px" height="120px" src="goods-images/${product.id}.jpg" alt="${product.name}" border="0">
														</a>
														<ul>
															<li class="gname"><a href="#">${product.name}</a></li>
															<li class="gmpirce"><b>市场均价:</b>￥${product.memberPrice}</li>
															<li class="hrpirce"><b>会员实价:</b>￥${product.normalPrice}</li>			
														</ul>									  
													</div>
												</td>
												</s:iterator>
												</tr>
											</tbody>
										</table>
									</div>
									
									<div class="hr-panel2-body" forcat="c11" style="display: none;">
										<table width="100%">
											<tbody>
												<tr>
												<s:iterator value="shoes" id="product">
												<td valign="top" width="25%">
													<div class="hr-goods-show">
														<a href="#" class="gpic">
															<img width="120px" height="120px" src="goods-images/${product.id}.jpg" alt="${product.name}" border="0">
														</a>
														<ul>
															<li class="gname"><a href="#">${product.name}</a></li>
															<li class="gmpirce"><b>市场均价:</b>￥${product.memberPrice}</li>
															<li class="hrpirce"><b>会员实价:</b>￥${product.normalPrice}</li>			
														</ul>									  
													</div>
												</td>
												</s:iterator>
												</tr>
											</tbody>
										</table>
									</div>
									
									</div>

								</div>
									
								<a class="hr-tag hr-hot-tag" href="#" target="_blank">&nbsp;</a>
							
								
							<script>
								void function(){
									var bt=new Array(2);
									var board=document.getElementById('hr-hot-body');
									var divs=board.getElementsByTagName('div');
									divs=(function(){
										var arr=[];
										for(var i=0;i<divs.length;i++){
											if(divs[i].getAttribute('forcat')){
												arr.push(divs[i]);
											}
										}
										return arr;
									})();
									secHotBody=function(index,handle){
									if(handle.className=='current')return;
									divs[index].style.display='block';
									handle.className='current';
									if(bt[0]){
										bt[0].className='';
										bt[1].style.display='none';
										}else{
											document.getElementById('first-hot-handle').className='';
											divs[0].style.display='none';
										}
										bt=[handle,divs[index]];
									};
								}();
							</script>

							<div class="hr-mod2-panel">
								<div class="hr-panel2-title"><h3>合作品牌</h3>
									<ul class="hr-float-list">
										<li>
											<a href="#">耐克</a>
										</li>
										<li>
											<a href="#">visvim</a>
										</li>
										<li>
											<a href="#">佳能</a>
										</li>
										<li>
											<a href="#">苹果</a>
										</li>
									</ul>
								</div>

								<div class="hr-panel2-body">
								<s:iterator value="newproducts" id="product">
								<div class="hr-goods-show hr-goods-show-float">
									<a href="#" class="gpic">
										<img alt="${product.name}" src="goods-images/${product.id}.jpg" align="top" height="120" width="120" /> 
									</a>
									<ul>
										<li class="gname">
											<a href="#">${product.name}</a>
										</li>
										<li class="gmpirce"><b>市场均价:</b>￥${product.normalPrice} </li>
										<li class="hrpirce"><b>会员实价:</b>￥${product.memberPrice} </li>							 
									</ul>									  
								</div>
								</s:iterator>
								</div>
							</div>
						</td>
					</tr>
				</tbody>
			</table>

			<div class="hr-gnsc-fbanner">
				<a href="#">在家就能享受到的购物天堂，放心，舒心，开心!</a>
			</div>
			<%@ include file="public/bottom.jsp" %>				
		</div>
	</div>
	<s:include value="public/foot.jsp" />
</body>
</html>
